The present invention relates to data communication networks, and in particular, to a system for accumulating data relating to various performance parameters, in order to determine their average values.
The growth in computer applications that require heavy data traffic and the increasing availability of high-speed transmission lines and intelligent communication switches create a need for computer systems able to manage a huge amount of data at high rates. High-speed communication networks may require a central processing unit (CPU) to be interrupted at rates of 20,000-100,000 interrupts per second in response to hundreds various events.
For example, an external CPU may periodically read various registers of a network controller to receive information on operating conditions and performance parameters of the controller. If the CPU accesses the controller registers at a high rate, processing bottlenecks may occur. However, if two successive CPU accesses to a particular register are separated by a relatively long time interval, values of parameters stored in the register may substantially change.
To optimize the network performance, it would be desirable to provide the CPU with data that enable the CPU to determine average values of performance parameters over a time interval between two successive CPU accesses.
Accordingly, a primary object of the present invention is to provide a system for accumulating data that enable a host to determine average values of performance parameters.
The above and other advantages of the invention are achieved, at least in part, by providing a system for accumulating information that comprises an event counter for counting the number of events relating to network parameters, and a timer for determining total time during which the events take place. In response to the determined number of events and total time, a host calculates an average value of the network parameters as a ratio of the total time to the number of events.
In accordance with a preferred embodiment of the invention, the timer may increment at a predetermined rate while an event relating to a network parameter occurs. The timer stops when the event comes to an end, and is activated to continue incrementing at the predetermined rate upon occurrence of a next event relating to the network parameter.
In accordance with a first aspect of the invention, the counter may count bus latency events relating to latency time of a system bus. The counter increments every time when a request for access to the system bus is produced. The timer is activated by the request and stops when the request is granted.
In accordance with another aspect of the invention, the counter may count interrupt latency events relating to interrupt latency time of a network controller. The counter increments every time when a request for interrupt of the host is produced. The timer is activated by the request and stops when the request is terminated.
In accordance with a further aspect of the invention, the counter may count receive service events relating to receive service time of a network controller. The counter increments every time when a first element of a frame is received by the network controller from a network. The timer is activated when the first element of the frame is received from the network, and stops when the frame is completely written to a system memory.
In accordance with another aspect of the invention, the counter may count events relating to time of transferring a frame from a buffer to a system memory. In this case, the counter increments every time when a first element of a received frame is written to the system memory. The timer is activated when the first element of the received frame is written to the system memory, and stops when the received frame is completely written to the system memory.
In accordance with a method of the present invention the following steps are carried out for accumulating data to determine average values of parameters:
counting number of events relating to the parameters, and
determining total time during which the events occur to calculate an average value of the parameters as a ratio of the total time to the number of events.
Still other objects and advantages of the present invention will become readily apparent to those skilled in this art from the following detailed description, wherein only the preferred embodiment of the invention is shown and described, simply by way of illustration of the best mode contemplated of carrying out the invention. As will be realized, the invention is capable of other and different embodiments, and its several details are capable of modifications in various obvious respects, all without departing from the invention. Accordingly, the drawings and description are to be regarded as illustrative in nature, and not as restrictive.